import { sendRequest } from '@/http';

/* 通过id查询 */
export const queryById = (id: string) =>
  sendRequest({
    url: '/admin/staff/info',
    method: 'get',
    params: { id },
  });

export const edit = (data: any) =>
  sendRequest({
    url: '/admin/staff/edit',
    method: 'post',
    data,
  });

export const add = (data: any) =>
  sendRequest({
    url: '/admin/staff/add',
    method: 'post',
    data,
  });

export const queryStaffAccountInfo = (userid: string) =>
  sendRequest({
    url: '/admin/account/queryStaffAccountInfo',
    method: 'get',
    params: { userid },
  });
